/**
 *
 */
package org.tangram.component.xml;

import org.simpleframework.xml.Attribute;

/**
 * @author han_feng
 * 
 */
public class DependencyDefintion {

	@Attribute
	private String groupId;

	@Attribute
	private String id;

	@Attribute
	private String version;

	public DependencyDefintion(@Attribute(name = "groupId") String groupId,
			@Attribute(name = "id") String id,
			@Attribute(name = "version") String version) {
		this.groupId = groupId;
		this.id = id;
		this.version = version;
	}

	/**
	 * @return the groupId
	 */
	public String getGroupId() {
		return groupId;
	}

	/**
	 * @return the id
	 */
	public String getId() {
		return id;
	}

	/**
	 * @return the version
	 */
	public String getVersion() {
		return version;
	}

	public String getKey() {
		return this.getGroupId() + ":" + this.getId();
	}

}
